package com.tangcl.module_base.log

import android.util.Log

/**
 * Created by TCL on 2021/7/7
 *
 * description:日志
 */
object LogUtils {
    private const val constTag = "输出LogUtils----"
    private const val constMsgTag = "----"

    //设为false关闭日志
    private const val LOG_ENABLE = true

    fun i(tag: String?, msg: String) {
        if (LOG_ENABLE) {
            Log.i(constTag + tag, constMsgTag + msg)
        }
    }

    fun v(tag: String?, msg: String) {
        if (LOG_ENABLE) {
            Log.v(constTag + tag, constMsgTag + msg)
        }
    }

    fun d(tag: String?, msg: String) {
        if (LOG_ENABLE) {
            Log.d(constTag + tag, constMsgTag + msg)
        }
    }

    fun w(tag: String?, msg: String) {
        if (LOG_ENABLE) {
            Log.w(constTag + tag, constMsgTag + msg)
        }
    }

    fun e(tag: String?, msg: String) {
        if (LOG_ENABLE) {
            Log.e(constTag + tag, constMsgTag + msg)
        }
    }
}